<template>
	<view class="record-detail">
		<!-- 背景色 -->
		<view class="record-detail-background"></view>
		<view class="record-detail-title">已预约</view>
		<!-- 猫咪&医生信息 -->
		<view class="record-detail-top-case">
			<view class="record-detail-pet-info">
				<text>就诊猫咪</text>
				<text>八月</text>
			</view>
			<view class="record-detail-time">2021/07/17 上午 8:40 第10号</view>
			<view class="record-detail-doctor-info">
				<image class="doctor-img" src="https://nabercat.oss-cn-hangzhou.aliyuncs.com/15456303108155.jpeg" mode="aspectFill"></image>
				<view class="record-item-doctor-info-right">
					<view class="record-item-doctor-name">
						<text>曹雨声</text>
						<text>动物医院院长</text>
					</view>
					<view class="record-item-doctor-number">执业编号：A012938790087</view>
				</view>
			</view>
		</view>
		<!-- 已预约 -->
		<!-- <view class="record-detail-map">
			<map class="map-dt" longitude="120.003090538" latitude="30.281164366" id="mapId" :markers="markers" @tap="controltap"></map>
			<view class="map-text">为了您猫咪的健康，请在规定时间内前往指定地点就医～</view>
		</view> -->
		<!-- 已取消 -->
		<!-- <view class="record-detail-canceled">
			<icon class="icon-YIQUXIAO"></icon>
			<text>您已取消该订单</text>
		</view> -->
		<!-- 已就诊 -->
		<view class="record-detail-see-doctor">
			<view class="record-detail-see-doctor-item">
				<text class="record-detail-see-doctor-item-title">症状描述：</text>
				<text>发烧，鼻子产生大量黏液，大喷嚏，结膜炎，角膜溃疡，大量流眼泪。</text>
			</view>
			<view class="record-detail-see-doctor-item">
				<text class="record-detail-see-doctor-item-title">就诊结果：</text>
				<text>结合临床验证，诊断结果为鼻气管炎（猫鼻支）。</text>
			</view>
			<view class="record-detail-see-doctor-item answer-chat-image-list">
				<image class="answer-chat-image-item" src="https://nabercat.oss-cn-hangzhou.aliyuncs.com/15456303108155.jpeg" mode="aspectFill"></image>
				<image class="answer-chat-image-item" src="https://nabercat.oss-cn-hangzhou.aliyuncs.com/15456303108155.jpeg" mode="aspectFill"></image>
				<image class="answer-chat-image-item" src="https://nabercat.oss-cn-hangzhou.aliyuncs.com/15456303108155.jpeg" mode="aspectFill"></image>
			</view>
			<view class="record-detail-see-doctor-item">
				<text class="record-detail-see-doctor-item-title">就诊建议：</text>
				<text>
					疱疹病毒株的细菌侵入到猫咪的呼吸道，这种病毒会附着在猫咪的气管内，并开始侵害它们的呼吸系统。另注意该病毒会通过空气传播，确定猫咪患有该症状后，请及时隔离其他猫咪。
				</text>
			</view>
			<view class="record-detail-see-doctor-item">
				<text class="record-detail-see-doctor-item-title">温馨提示：</text>
				<text>请按照医生开具的指定药物给猫咪进行服用，希望您的猫咪早日康复！</text>
			</view>
		</view>
		<!-- 订单信息 -->
		<view class="record-detail-order-info">
			<view class="record-detail-order-info-item">
				<text class="order-info-title">订单编号：</text>
				<text class="order-info-content">698750702</text>
			</view>
			<view class="record-detail-order-info-item">
				<text class="order-info-title">创建时间：</text>
				<text class="order-info-content">2021/07/02 10:15:54</text>
			</view>
		</view>
	</view>
</template>

<script>
export default {
	data() {
		return {
			markers: [
				{
					iconPath: 'https://nabercat.oss-cn-hangzhou.aliyuncs.com/15456303108155.jpeg',
					id: 0,
					latitude: 30.281164366,
					longitude: 120.003090538,
					width: 20,
					height: 20
				}
			]
		};
	},
	methods: {
		// 打开地图
		controltap(e) {
			uni.openLocation({
				latitude: 30.281164366,
				longitude: 120.003090538
			});
		}
	},
	onLoad(options) {}
};
</script>

<style scoped lang="scss">
.record-detail {
	padding: 46rpx 32rpx;
	.record-detail-background {
		position: fixed;
		top: 0;
		left: 0;
		right: 0;
		height: 250rpx;
		background: #34d1a9;
		z-index: -9999;
	}
	.record-detail-title {
		font-size: 36rpx;
		font-weight: 600;
		color: #ffffff;
		line-height: 50rpx;
		text-align: center;
		margin-bottom: 30rpx;
	}
	.record-detail-top-case {
		padding: 32rpx 20rpx 38rpx;
		background: #ffffff;
		border-radius: 16rpx;
		font-size: 28rpx;
		margin-bottom: 30rpx;
		.record-detail-pet-info {
			color: #999999;
			line-height: 40rpx;
			padding: 0 10rpx 22rpx;
			border-bottom: 2rpx dashed #f1f1f1;
			margin-bottom: 32rpx;
			& > text:nth-of-type(1) {
				margin-right: 28rpx;
			}
		}
		.record-detail-time {
			padding: 0 10rpx;
			color: #999999;
			line-height: 40rpx;
			margin-bottom: 20rpx;
		}
		.record-detail-doctor-info {
			padding: 0 10rpx;
			display: flex;
			.doctor-img {
				width: 116rpx;
				height: 116rpx;
				background: #dcdddd;
				border-radius: 16rpx;
				margin-right: 16rpx;
			}
			.record-item-doctor-info-right {
				flex: 1;
				.record-item-doctor-name {
					display: flex;
					align-items: center;
					color: #666666;
					margin-bottom: 8rpx;
					& > text:nth-of-type(1) {
						font-size: 36rpx;
						font-weight: 500;
						color: #333333;
						line-height: 50rpx;
						margin-right: 20rpx;
					}
				}
				.record-item-doctor-number {
					color: #666666;
					line-height: 40rpx;
				}
			}
		}
	}
	.record-detail-map {
		width: 100%;
		height: 342rpx;
		border-radius: 0 0 16rpx 16rpx;
		overflow: hidden;
		position: relative;
		background: #ffffff;
		.map-dt {
			width: 100%;
			height: 100%;
		}
		.map-text {
			width: 100%;
			height: 72rpx;
			background: linear-gradient(180deg, #34d1a9 0%, #34d1a9 100%);
			font-size: 24rpx;
			font-weight: 500;
			color: #ffffff;
			line-height: 72rpx;
			text-align: center;
			position: absolute;
			bottom: 0;
			left: 0;
		}
	}
	.record-detail-see-doctor {
		background: #ffffff;
		border-radius: 16rpx;
		padding: 28rpx;
		font-size: 28rpx;
		line-height: 40rpx;
		color: #999999;
		max-height: 700rpx;
		box-sizing: border-box;
		overflow-y: auto;
		.record-detail-see-doctor-item {
			margin-bottom: 32rpx;
			&:nth-last-of-type(1) {
				margin-bottom: 0;
			}
			.record-detail-see-doctor-item-title {
				font-weight: 600;
				color: #34d1a9;
			}
		}
	}
	.answer-chat-image-list {
		display: flex;
		flex-wrap: wrap;
		margin-top: 16rpx;
		justify-content: space-between;
		.answer-chat-image-item {
			width: 174rpx;
			height: 112rpx;
			margin-bottom: 10rpx;
			&:nth-last-of-type(-n + 3) {
				margin-bottom: 0;
			}
		}
		&::after {
			content: '';
			width: 174rpx;
			height: 0px;
			visibility: hidden;
		}
	}
	.record-detail-canceled {
		width: 100%;
		height: 400rpx;
		background: #ffffff;
		border-radius: 16rpx;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		.icon-YIQUXIAO {
			width: 240rpx;
			height: 240rpx;
			background: url(https://nabercat.oss-cn-hangzhou.aliyuncs.com/pet-hospital/icon-recorddetail-yiquxiao.png) no-repeat center center;
			background-size: 214rpx 180rpx;
		}
		& > text {
			font-size: 28rpx;
			color: #999999;
			line-height: 40rpx;
		}
	}
	/* 
	 <view class="record-detail-canceled">
	 	<icon class="icon-YIQUXIAO"></icon>
	 	<text>您已取消该订单</text>
	 </view>
	 */
	.record-detail-order-info {
		padding: 28rpx;
		font-size: 24rpx;
		color: #666666;
		line-height: 34rpx;
		background: #ffffff;
		border-radius: 16rpx;
		margin-top: 30rpx;
		.record-detail-order-info-item {
			margin-bottom: 16rpx;
			&:nth-last-of-type(1) {
				margin-bottom: 0;
			}
			.order-info-title {
				color: #999999;
				margin-right: 16rpx;
			}
		}
	}
}
</style>
<style>
page {
	background: #f1f1f1;
}
</style>
